<!DOCTYPE html>
<html>
<!-- Created by GNU Texinfo 7.1, https://www.gnu.org/software/texinfo/ -->
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<!-- This file documents the use of the GNU compilers.

Copyright © 1988-2023 Free Software Foundation, Inc.

Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.3 or
any later version published by the Free Software Foundation; with the
Invariant Sections being "Funding Free Software", the Front-Cover
Texts being (a) (see below), and with the Back-Cover Texts being (b)
(see below).  A copy of the license is included in the section entitled
"GNU Free Documentation License".

(a) The FSF's Front-Cover Text is:

A GNU Manual

(b) The FSF's Back-Cover Text is:

You have freedom to copy and modify this GNU Manual, like GNU
     software.  Copies published by the Free Software Foundation raise
     funds for GNU development. -->
<title>Standard Libraries (Using the GNU Compiler Collection (GCC))</title>

<meta name="description" content="Standard Libraries (Using the GNU Compiler Collection (GCC))">
<meta name="keywords" content="Standard Libraries (Using the GNU Compiler Collection (GCC))">
<meta name="resource-type" content="document">
<meta name="distribution" content="global">
<meta name="Generator" content="makeinfo">
<meta name="viewport" content="width=device-width,initial-scale=1">

<link href="index.html" rel="start" title="Top">
<link href="Indices.html" rel="index" title="Indices">
<link href="index.html#SEC_Contents" rel="contents" title="Table of Contents">
<link href="Trouble.html" rel="up" title="Trouble">
<link href="Disappointments.html" rel="next" title="Disappointments">
<link href="Fixed-Headers.html" rel="prev" title="Fixed Headers">
<style type="text/css">
<!--
a.copiable-link {visibility: hidden; text-decoration: none; line-height: 0em}
kbd.key {font-style: normal}
span:hover a.copiable-link {visibility: visible}
-->
</style>


</head>

<body lang="en_US">
<div class="section-level-extent" id="Standard-Libraries">
<div class="nav-panel">
<p>
Next: <a href="Disappointments.html" accesskey="n" rel="next">Disappointments and Misunderstandings</a>, Previous: <a href="Fixed-Headers.html" accesskey="p" rel="prev">Fixed Header Files</a>, Up: <a href="Trouble.html" accesskey="u" rel="up">Known Causes of Trouble with GCC</a> &nbsp; [<a href="index.html#SEC_Contents" title="Table of contents" rel="contents">Contents</a>][<a href="Indices.html" title="Index" rel="index">Index</a>]</p>
</div>
<hr>
<h3 class="section" id="Standard-Libraries-1"><span>14.5 Standard Libraries<a class="copiable-link" href="#Standard-Libraries-1"> &para;</a></span></h3>

<a class="index-entry-id" id="index-Wall-1"></a>
<p>GCC by itself attempts to be a conforming freestanding implementation.
See <a class="xref" href="Standards.html">Language Standards Supported by GCC</a>, for details of
what this means.  Beyond the library facilities required of such an
implementation, the rest of the C library is supplied by the vendor of
the operating system.  If that C library doesn&rsquo;t conform to the C
standards, then your programs might get warnings (especially when using
<samp class="option">-Wall</samp>) that you don&rsquo;t expect.
</p>
<p>For example, the <code class="code">sprintf</code> function on SunOS 4.1.3 returns
<code class="code">char *</code> while the C standard says that <code class="code">sprintf</code> returns an
<code class="code">int</code>.  The <code class="code">fixincludes</code> program could make the prototype for
this function match the Standard, but that would be wrong, since the
function will still return <code class="code">char *</code>.
</p>
<p>If you need a Standard compliant library, then you need to find one, as
GCC does not provide one.  The GNU C library (called <code class="code">glibc</code>)
provides ISO C, POSIX, BSD, SystemV and X/Open compatibility for
GNU/Linux and HURD-based GNU systems; no recent version of it supports
other systems, though some very old versions did.  Version 2.2 of the
GNU C library includes nearly complete C99 support.  You could also ask
your operating system vendor if newer libraries are available.
</p>
</div>



</body>
</html>
